﻿@model CharacterCreation.Business.ViewModels.VMCharacterStatisticXPDetail
@using CharacterCreation.Business.ViewModels

@{
    ViewBag.Title = "StatisticDetail";
}

<h2>StatisticDetail</h2>

<fieldset>
    @foreach (VMCharacterStatisticXPDetail xpd in ViewBag.XPDetails)
    {
        <hr />
        @Html.LabelFor(x => x.XP) 
        @Html.DisplayFor(x => xpd.XP)
        @Html.ActionLink("Delete", "DeleteStatisticDetail", new { characterStatisticXPDetailId = xpd.Id, characterStatisticId = xpd.CharacterStatisticId })
    }
</fieldset>


@using (Html.BeginForm())
{
    @Html.ValidationSummary(true)
    <fieldset>
            
        @Html.HiddenFor(m => m.Id)
        @Html.HiddenFor(m => m.CharacterId)
        @Html.HiddenFor(m => m.CharacterStatisticId)
        @Html.HiddenFor(m => m.DateReceived)

        <dl>
            <hr />

            <dt>@Html.LabelFor(model => model.XP)</dt>
            <dd>@Html.EditorFor(model => model.XP)</dd>
            
            <hr />

            <dt>@Html.LabelFor(model => model.Reason)</dt>
            <dd>@Html.EditorFor(model => model.Reason)</dd>

            <hr />
            
            <dt>@Html.LabelFor(model => model.Package)</dt>
            <dd>@Html.EnumDropDownListFor(model => model.Package)</dd>

            <hr />
            
        </dl>
        
        <input type="submit" value="Save" class="button" />
        @Html.ActionLink("Return to character", "Details", new { id = ViewBag.CharacterId }, new { @class = "button" })
    </fieldset>
}